package com.ruoyi.web.controller.production;

import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.production.domain.ProductionWorkOrder;
import com.ruoyi.production.service.IProductionInWarehouseService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/production/inWarehouse")
public class ProductionInWarehouseController extends BaseController {
    @Autowired
    private IProductionInWarehouseService productionInWarehouseService;

    //生产入库
    @PostMapping
    public AjaxResult add(@RequestBody ProductionWorkOrder productionWorkOrder) {
        return toAjax(productionInWarehouseService.addProductionInWarehouse(productionWorkOrder.getId()));
    }

}
